﻿using System;
using System.Collections.Generic;
using System.Data.Entity.ModelConfiguration;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Himall.Entity.Config
{
   public class AttributeValueInfoConfig : EntityTypeConfiguration<AttributeValueInfo>
    {
        public AttributeValueInfoConfig()
        {
            ToTable("Himall_AttributeValues");
            Property(item => item.Value).HasColumnType("varchar").HasMaxLength(50);           
            HasRequired(x => x.AttributesInfo).WithMany(x => x.AttributeValueInfo).HasForeignKey(x => x.AttributeId);
        }
    }
}
